from django.db import models
from django_mysql.models import Model


class BaseModel(Model):
    # BaseModel
    operator_name = models.CharField(
        "操作人名称",
        max_length=20,
        blank=True,
        default="",
    )
    delete_time = models.DateTimeField(
        "删除时间",
        help_text="删除时间",
        null=True,
        blank=True,
    )
    create_time = models.DateTimeField(
        "添加时间",
        help_text="添加时间",
        auto_now_add=True,
    )
    update_time = models.DateTimeField(
        "更新时间",
        help_text="更新时间",
        auto_now=True,
    )
    class Meta:
        abstract = True